import {Inject, Injectable} from '@angular/core';
import {HttpClient} from '@angular/common/http';
import {Observable} from 'rxjs';

@Injectable({
  providedIn: 'root'
})
export class SmarketComponentsLibService {


  constructor(private http: HttpClient,
              @Inject('BASE_CONFIG') private BASE_CONFIG: any) {
  }

  getHeaderData(): Observable<any> {
    return this.http.get(this.BASE_CONFIG.API + this.BASE_CONFIG.HEADER);
  }

  getFooterData(): Observable<any> {
    return this.http.get(`${this.BASE_CONFIG.API}/footer`);
  }
}
